<?php

class ReservasPersonasTable extends Doctrine_Table
{
	public function getPersonaResponsableReserva($idReserva){
		$q = Doctrine_Query::create()
		  ->from('ReservasPersonas r')
		  ->where('r.reserva_id = ?', $idReserva)
		  ->andWhere('r.responsablereserva = ?', 1)
		  ;
		  $coll = $q->execute();
		  return $coll->getFirst();
	}
}